<template>
	<view class="box-preview-swiper">{{ current_item_index + 1 }} / {{ total }}</view>
</template>

<script setup>
import { onLoad } from '@dcloudio/uni-app'
import { inject, ref } from 'vue'

const total = ref(null)

onLoad((obj) => {
	total.value = obj.total
	console.log(total)
})

const current_item_index = inject('current_item_index')
</script>

<style scoped lang="scss">
.box-preview-swiper {
	line-height: 30rpx;
	font-size: 20rpx;
	border: 1rpx solid #eee;
	border-radius: 100rpx;
	background-color: rgba(0, 0, 0, 0.2);
	padding: 0rpx 16rpx;
	@extend .f-c-c-n;
}
</style>
